package com.flyan.game.motafx.core.equip;

import cn.hutool.core.collection.CollUtil;
import lombok.Data;

import java.util.Set;

/**
 * 装备面板
 *
 * @author flyan
 * @version 1.0
 * @email flyan_by_chenu@sina.com
 * @since 2025/2/6
 */
@Data
public class EquipPanel implements Cloneable {

    /**
     * 攻击力
     */
    private int ack;

    /**
     * 防御力
     */
    private int def;

    /**
     * 能力/属性
     */
    private Set<String> abilities;

    @Override
    public EquipPanel clone() {
        try {
            EquipPanel clone = (EquipPanel) super.clone();
            clone.setAbilities(CollUtil.newHashSet(abilities));
            return clone;
        } catch (CloneNotSupportedException e) {
            throw new AssertionError();
        }
    }

}
